const WinningReward = () => {
  // 列表数据
  const listData = [] as any;

  for (let i = 1; i < 15; i++) {
    const ran = Math.floor(Math.random() * 2);
    listData.push({
      id: i,
      name: i + "连胜",
      datetime: "2024-12-01  12:00",
      type: ran,
      power: Math.floor(Math.random() * 100),
    });
  }

  return (
    <ul>
      {listData.map((item: any) => (
        <li key={item.id} className="item">
          <div className={item.id < 3 ? "item-box item-yellow" : "item-box"}>
            <div className="left-box">
              <div className="how-win">
                <span className="name">{item.name}</span>
              </div>
            </div>
            <div className="right-box">
              <div className="attr-name">
                <img src="../images/gold_coin.png" />
                <div className="name">大量金币</div>
              </div>
              {item.id < 3 ? (
                <img className="receive-img" src="../images/already_re.png" />
              ) : item.id > 4 ? (
                <div className="btn btn-gray">未完成</div>
              ) : (
                <div className="btn">立即领取</div>
              )}
            </div>
          </div>
        </li>
      ))}
    </ul>
  );
};

export default WinningReward;
